/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package apt;

import java.util.Scanner;

/**
 *
 * @author lhminh
 */
public class MangSoNguyen {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
        // TODO code application logic here
        Scanner scanner = new Scanner(System.in);
        
        int n = 0;
        int[] a;
        
        System.out.print("Nhap n: ");
        n = scanner.nextInt();
        a = new int[n];
        
        System.out.println("Chieu dai cua mang la: " + a.length);
        
        for (int i = 0; i < a.length; i++) {
            System.out.print("Nhap a[" + i + "] = ");
            a[i] = scanner.nextInt();
        }
        
        for (int i = 0; i < a.length; i++) {
            System.out.print(a[i] + " ");
        }
    }
    
    
}
